<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>固定定位</title>
		<style>
			#d1{
				width: 1000px;
				height: 100px;
				background-color: red;
				/* 设置固定定位:脱离文档流 */
				position: fixed;
				/* 让元素贴着最上方 */
				top: 0;
			}
			body{
				padding: 100px;
			}
			#d2{
				width: 50px;
				height: 200px;
				background-color: blue;
				position: fixed;
				bottom: 0;
				right: 0;
			}
		</style>
	</head>
	<body>
		<div id="d1"></div>
		<div id="d2"></div>
		<img src="../notos/img/image-20230818203113547.png" alt="">
		<img src="../notos/img/image-20230818203113547.png" alt="">
		<img src="../notos/img/image-20230818203113547.png" alt="">
		<img src="../notos/img/image-20230818203113547.png" alt="">
		<img src="../notos/img/image-20230818203113547.png" alt="">
		<img src="../notos/img/image-20230818203113547.png" alt="">
		<img src="../notos/img/image-20230818203113547.png" alt="">
		 <img src="../notos/img/image-20230818203113547.png" alt="">
	</body>
</html>